1. Field of the Disclosure
The present disclosure generally relates to a method and apparatus for batch processing of data in an electronic device.
2. Description of the Related Art
An electronic device includes various sensors and, by using these sensors, an application which provides a user with a service such as fitness tracking, location tracking, monitoring by recognizing the peripheral situation of the electronic device and the current condition of the user or the electronic device, has been developed. For example, functions for tracking a moving path of an electronic device moving in real-time and displaying the moving path on a map on a display, such as a touch screen, can be provided. In addition, such an application is driven by interacting with a variety of sensors, which are installed in the electronic device, such as a GPS, an acceleration sensor, an angular velocity sensor, a temperature sensor, a pressure sensor, an atmospheric pressure sensor, a flow sensor, a geomagnetic sensor, an optical sensor, a sound sensor, and a taste sensor, where the sensors are either driven in the background while the other applications are driven or are driven simultaneously along with the other applications. Accordingly, the electronic device is required to quickly process a relatively large amount of data, and thus, demands a high-performance processor.
To reduce power consumption, the electronic device can use a data batching scheme in which data measured by various sensors is collected and stored for a predetermined time by a low power processor and data collected at a particular time is collectively transmitted by a high-performance processor.
Since electronic devices generally operate using a small sized battery having a small capacity, a problem of fast power consumption may occur when various applications are driven through a high-performance processor.
In addition, in a data batching scheme of transmitting data of various sensors collected by a low power processor through a high-performance processor when a fitness service for setting a goal regarding, for example, exercise time, exercise distance, a number of steps, or calories to burn by a user, and for notifying of success or failure in achieving the set goal in the fitness service of an application, the corresponding application inevitably receives, in real time, sensing data collected by the low power processor in order to check whether the exercise goal has been achieved; and when the application has the sensing data batch-processed at regular periods, there may exist a difference between the batch processing period and the time of the exercise goal, which may result in an inaccurate notification of the achievement of an exercise goal. As a result, an accurate notification service for the achievement of the exercise goal is needed.